﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace CastingWellEquipmentGUI.View.Pages
{
    /// <summary>
    /// CreateRecipePage.xaml 的交互逻辑
    /// </summary>
    public partial class CreateRecipePage : Page
    {
        public CreateRecipePage()
        {
            InitializeComponent();
        }

        public static CreateRecipePage instance;

        public static CreateRecipePage Instance
        {
            get
            {
                if (instance == null)
                {
                    Console.WriteLine("new Page1.................");
                    instance = new CreateRecipePage();
                }

                return instance;
            }
        }

        private void TextBox_Diameter_PreviewTextInput(object sender, TextCompositionEventArgs e)
        {
            e.Handled = new Regex("[^0-9]+").IsMatch(e.Text);
        }


    }
}
